<?php

namespace App\Enum;

use App\Enum\BaseEnum;

class SopTypeEnum extends BaseEnum
{
    const STANDARD =  1;
    const TAG =  2;
    const NEW =  3;
    const CROWD =  4;

    public static function getMap(): array
    {
        return [
            self::STANDARD => '标准模板',
            self::TAG => '标签SOP模板',
            self::NEW => '新用户模板',
            self::CROWD => '群模板'
        ];
    }

    public static $sopBaseConf = [
        self::STANDARD => [
            'send_type' => 1, //1时间段随机发送  2时间点精确发送
            'conf' => [
                1 =>  [
                    'send_time_start' => '08:00',
                    'send_time_end' => '10:00',
                ],
                2 =>  [],
            ]
        ],
        self::TAG => [
            'send_type' => 1, //1打上标签后开始任务   2打上标签后随机开始发送任务  3指定时间开始任务
            'conf' => [
                1 =>  [
                    'before_hour' => 1,
                    'before_minute' => 1,
                ],
                2 =>  [
                    'before_day' => 1,
                    'send_time_start' => '08:00',
                    'send_time_end' => '10:00',
                ],
                3 =>  [
                    'appoint_day' => '',
                    'send_time_start' => '08:00',
                    'send_time_end' => '10:00',
                ]
            ],
        ],
        self::NEW => [
            'send_type' => 1, //1成为好友法1小时发送   2成为好友定时发送
            'conf' => [
                1 =>  [
                    'before_hour' => 1,
                    'before_minute' => 1,
                ],
                2 =>  [
                    'before_day' => 1,
                    'send_time_start' => '08:00',
                    'send_time_end' => '10:00',
                ],
            ],
        ],
        self::CROWD => [
            'send_type' => 1, //1群满足条件1小时发送   2指定时间发送
            'conf' => [
                1 =>  [
                    'before_hour' => 1,
                    'before_minute' => 1,
                ],
                2 =>  [
                    'appoint_day' => '',
                    'send_time_start' => '08:00',
                    'send_time_end' => '10:00',
                ],
            ],
        ],
    ];


}